<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <title></title>
    <script type="text/javascript" src="__PUBLIC__/Js/jquery-1.7.2.min.js"></script>
    <!--<script type="text/javascript" src="__PUBLIC__/Js/search.js"></script>-->
    <link rel="stylesheet" href="__PUBLIC__/Css/public.css"/>
</head>
<body>
<a href="<?php echo U('Admin/Excel/see');?>">返回</a>
<hr/>
<p>
    <form action="<?php echo U('Admin/Excel/down');?>" method="post">
    <span style="color: #0000ff;"><?php echo ($s_y); ?></span>
    <input type="hidden" value="<?php echo ($s_y); ?>" name="school_year">
    <span>学年</span>
    <span>第</span>
    <span style="color: fuchsia;"><?php echo ($term); ?></span>
    <input type="hidden" value="<?php echo ($term); ?>" name="term">
    <span>学期</span>
    <span style="color: red;"><?php echo ($class); ?></span>
    <input type="hidden" value="<?php echo ($class); ?>" name="class">
    <input type="submit" value="导出Excel">
</form>
</p>


<table class="table">
    <tr>
        <th>学籍号</th>
        <th>考号</th>
        <th>姓名</th>
        <?php if(is_array($all_s_n)): foreach($all_s_n as $key=>$vv): ?><th><?php echo ($vv["subject"]); ?></th><?php endforeach; endif; ?>
        <th>平均分</th>
        <th>总分</th>
        <th>合格科目数</th>
        <th>班级等级</th>
        <th>全校等级</th>
        <th>操作</th>

    </tr>
    <?php if(is_array($all_info)): foreach($all_info as $key=>$v): ?><tr>
            <td><?php echo ($v["student_number"]); ?></td>
            <td><?php echo ($v["test_number"]); ?></td>
            <td><?php echo ($v["student_name"]); ?></td>
            <?php $i=0; ?>
            <?php if(is_array($all_s_n)): foreach($all_s_n as $key=>$vv): ?><td><?php echo ($v["$i"]); ?></td>
                <?php $i++; endforeach; endif; ?>
            <td><?php echo ($v["average"]); ?></td>
            <td><?php echo ($v["total_points"]); ?></td>
            <td><?php echo ($v["standard"]); ?></td>
            <td><?php echo ($v["class_order"]); ?></td>
            <td><?php echo ($v["schol_order"]); ?></td>
            <td><a href="<?php echo U('Admin/Excel/edit',array('test_number'=>$v['test_number'], 'average'=>$v['average'],'total_points'=>$v['total_points'],'standard'=>$v['standard'], 'class_order'=>$v['class_order'],'schol_order'=>$v['schol_order']));?>">编辑</a></td>
        </tr><?php endforeach; endif; ?>
</table>
</body>
</html>